#ifndef MODEL_H
#define MODEL_H

#include <QGraphicsScene>
#include <QPen>
#include <QRectF>
#include <QString>
#include "mainwindow.h"

class Model : public QGraphicsScene{
    public:
        Model():QGraphicsScene(QRectF(0,0,1600,1600)){ m_name = NULL; }
        ~Model(){}

        void setMainWindow(MainWindow* mainWindow){ m_mainWindow = mainWindow; }
        void setModelName (const QString newName){
            if (m_name) {
                *m_name = newName;
                return;
            }else{
                m_name = new QString(newName);
                return;
            }
        }
        void resetModelName(){m_name = NULL;}
        QString* name() {  return m_name; }

    private:
        MainWindow* m_mainWindow;
        QString* m_name;
};

#endif // MODEL_H
